package org.example.what_mall.entity;


import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

@TableName("spec")
@Data
@AllArgsConstructor
@NoArgsConstructor
@Builder
public class Spec {
    @Schema(description = "规格id")
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    @Schema(description = "商品id")
    @TableField(value = "goodsId")
    private Integer goodsId;

    @Schema(description = "规格名")
    @TableField(value = "specName")
    private String specName;

    @Schema(description = "库存")
    @TableField(value = "stockNum")
    private Integer stockNum;

    @Schema(description = "单位值")
    @TableField(value = "unitPrice")
    private Integer unitPrice;
}
